package locations.actions;

import java.util.Collection;
import java.util.LinkedList;

import locations.model.Practica;

import com.opensymphony.xwork2.ActionSupport;
import locations.dao.implement.UserDAOHibernateJPA;
import locations.model.Usuario;

public class UserIndexAction extends ActionSupport {

    private static final long serialVersionUID = 1L;
    private Long id;
    private Collection<Usuario> users = new LinkedList<Usuario>();

    public String execute() {
            UserDAOHibernateJPA dao = new UserDAOHibernateJPA();
            this.setUsers(dao.getAllValid());
            return SUCCESS;
    }

    public static long getSerialversionuid() {
            return serialVersionUID;
    }

    public Long getId() {
            return id;
    }

    public void setId(Long id) {
            this.id = id;
    }

    public Collection<Usuario> getUsers() {
        return users;
    }

    public void setUsers(Collection<Usuario> users) {
        this.users = users;
    }

}
